<template>
  <div class="app-container">
    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
      <div class="my_title">文件信息表</div>
      <el-form-item label="文件id" prop="fileId">
        <el-input
            v-model="queryParams.fileId"
            placeholder="请输入文件id"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="文件编号" prop="efilenum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.efilenum"
            placeholder="请输入文件编号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="listnum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.listnum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="列表号" prop="listId" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.listId"
            placeholder="请输入列表号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="索引id" prop="indexId" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.indexId"
            placeholder="请输入索引id"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="pid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.pid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="ID" prop="projid" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.projid"
            placeholder="请输入ID"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="dwid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.dwid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="fbid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fbid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="fxid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fxid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="jid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.jid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="topnode">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.topnode"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="topnodem">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.topnodem"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="案卷ID" prop="volumeid">
        <el-input
            v-model="queryParams.volumeid"
            placeholder="请输入案卷ID"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="旧案卷ID" prop="oldvolumeid" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.oldvolumeid"
            placeholder="请输入旧案卷ID"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="visflag">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.visflag"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="filingflag">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.filingflag"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="保存标志" prop="saveflag" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.saveflag"
            placeholder="请输入保存标志"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="openflag">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.openflag"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="检查标志" prop="checkupflag" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.checkupflag"
            placeholder="请输入检查标志"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="完成标志" prop="finishflag" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.finishflag"
            placeholder="请输入完成标志"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="fromid">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fromid"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="文件题名" prop="filename">
        <el-input
            v-model="queryParams.filename"
            placeholder="请输入文件题名"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="责任者" prop="duty" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.duty"
            placeholder="请输入责任者"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="文件编号" prop="tagnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tagnum"
            placeholder="请输入文件编号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="filenum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.filenum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="主题词" prop="thematic" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.thematic"
            placeholder="请输入主题词"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="创建时间" prop="ctime" v-if="showAdvancedSearch">
        <el-date-picker clearable
                        v-model="queryParams.ctime"
                        type="date"
                        value-format="yyyy-MM-dd"
                        placeholder="请选择创建时间">
        </el-date-picker>
      </el-form-item>
      <el-form-item label="页数" prop="pagenumber" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.pagenumber"
            placeholder="请输入页数"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="密级" prop="securitylayer" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.securitylayer"
            placeholder="请输入密级"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="卷内目录中页号" prop="pageno" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.pageno"
            placeholder="请输入卷内目录中页号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="全宗号" prop="fontsnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.fontsnum"
            placeholder="请输入全宗号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="保存期限" prop="savetime" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.savetime"
            placeholder="请输入保存期限"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="文件时间" prop="filetime" v-if="showAdvancedSearch">
        <el-date-picker clearable
                        v-model="queryParams.filetime"
                        type="date"
                        value-format="yyyy-MM-dd"
                        placeholder="请选择文件时间">
        </el-date-picker>
      </el-form-item>
      <el-form-item label="文件号" prop="fileno" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.fileno"
            placeholder="请输入文件号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="附件" prop="fileatt" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.fileatt"
            placeholder="请输入附件"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="ptext">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.ptext"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="carrieru">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.carrieru"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="glidenum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.glidenum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="验收日期" prop="ftime" v-if="showAdvancedSearch">
        <el-date-picker clearable
                        v-model="queryParams.ftime"
                        type="date"
                        value-format="yyyy-MM-dd"
                        placeholder="请选择验收日期">
        </el-date-picker>
      </el-form-item>
      <el-form-item label="文件总数量" prop="totalnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.totalnum"
            placeholder="请输入文件总数量"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="inputman">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.inputman"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="etime">-->
      <!--        <el-date-picker clearable-->
      <!--                        v-model="queryParams.etime"-->
      <!--                        type="date"-->
      <!--                        value-format="yyyy-MM-dd"-->
      <!--                        placeholder="请选择${comment}">-->
      <!--        </el-date-picker>-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="dotnum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.dotnum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="图片数量" prop="picnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.picnum"
            placeholder="请输入图片数量"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="recnum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.recnum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="总数量" prop="total" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.total"
            placeholder="请输入总数量"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="iscom">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.iscom"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="islocate">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.islocate"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="建设单位" prop="buildorganization" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.buildorganization"
            placeholder="请输入建设单位"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="编制单位" prop="wcompanyId" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.wcompanyId"
            placeholder="请输入编制单位"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="sendflag">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.sendflag"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="录制公司" prop="lcompany" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.lcompany"
            placeholder="请输入录制公司"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="录制人" prop="lman" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.lman"
            placeholder="请输入录制人"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="带长" prop="llen" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.llen"
            placeholder="请输入带长"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="录制时间" prop="ldate" v-if="showAdvancedSearch">
        <el-date-picker clearable
                        v-model="queryParams.ldate"
                        type="date"
                        value-format="yyyy-MM-dd"
                        placeholder="请选择录制时间">
        </el-date-picker>
      </el-form-item>
      <el-form-item label="事由" prop="jconten" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jconten"
            placeholder="请输入事由"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="地点" prop="jplace" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jplace"
            placeholder="请输入地点"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="人物" prop="jman" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jman"
            placeholder="请输入人物"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="背景" prop="jback" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jback"
            placeholder="请输入背景"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="摄影者" prop="jactor" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jactor"
            placeholder="请输入摄影者"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="jnum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.jnum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="底片号" prop="jbnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.jbnum"
            placeholder="请输入底片号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="图号" prop="tnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tnum"
            placeholder="请输入图号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="图纸比例" prop="tzoom" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tzoom"
            placeholder="请输入图纸比例"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="tflag">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.tflag"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="设计者" prop="tdesigner" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tdesigner"
            placeholder="请输入设计者"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="tviewer">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.tviewer"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="审核" prop="tassessor" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tassessor"
            placeholder="请输入审核"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="版本" prop="tvision" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.tvision"
            placeholder="请输入版本"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="clistno">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.clistno"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="cpageno">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.cpageno"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="档号" prop="vnum" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.vnum"
            placeholder="请输入档号"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="cvnum">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.cvnum"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="ctimeEnd">-->
      <!--        <el-date-picker clearable-->
      <!--                        v-model="queryParams.ctimeEnd"-->
      <!--                        type="date"-->
      <!--                        value-format="yyyy-MM-dd"-->
      <!--                        placeholder="请选择${comment}">-->
      <!--        </el-date-picker>-->
      <!--      </el-form-item>-->
      <el-form-item label="项目索引" prop="projIndex" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.projIndex"
            placeholder="请输入项目索引"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="${comment}" prop="treeParent">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.treeParent"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="${comment}" prop="treeList">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.treeList"-->
      <!--          placeholder="请输入${comment}"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item label="附注" prop="comments" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.comments"
            placeholder="请输入附注"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="摘要" prop="abstracts" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.abstracts"
            placeholder="请输入摘要"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="关键字" prop="keywords" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.keywords"
            placeholder="请输入关键字"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="电子文件存放路径" prop="filepath" v-if="showAdvancedSearch">
        <el-input
            v-model="queryParams.filepath"
            placeholder="请输入电子文件存放路径"
            clearable
            @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <!--      <el-form-item label="文件信息预留1" prop="fileReserved1">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fileReserved1"-->
      <!--          placeholder="请输入文件信息预留1"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="文件信息预留2" prop="fileReserved2">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fileReserved2"-->
      <!--          placeholder="请输入文件信息预留2"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="文件信息预留3" prop="fileReserved3">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fileReserved3"-->
      <!--          placeholder="请输入文件信息预留3"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <!--      <el-form-item label="文件信息预留4" prop="fileReserved4">-->
      <!--        <el-input-->
      <!--          v-model="queryParams.fileReserved4"-->
      <!--          placeholder="请输入文件信息预留4"-->
      <!--          clearable-->
      <!--          @keyup.enter.native="handleQuery"-->
      <!--        />-->
      <!--      </el-form-item>-->
      <el-form-item>
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
        <el-button type="success" icon="el-icon-sort" size="mini" @click="toggleSearchMode">高级搜索</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
      </el-form-item>
    </el-form>

    <el-row :gutter="10" class="mb8">
      <!--      <el-col :span="1.5">-->
      <!--        <el-button-->
      <!--          type="primary"-->
      <!--          plain-->
      <!--          icon="el-icon-plus"-->
      <!--          size="mini"-->
      <!--          @click="handleAdd"-->
      <!--          v-hasPermi="['system:info:add']"-->
      <!--        >新增</el-button>-->
      <!--      </el-col>-->
      <!--      <el-col :span="1.5">-->
      <!--        <el-button-->
      <!--          type="success"-->
      <!--          plain-->
      <!--          icon="el-icon-edit"-->
      <!--          size="mini"-->
      <!--          :disabled="single"-->
      <!--          @click="handleUpdate"-->
      <!--          v-hasPermi="['system:info:edit']"-->
      <!--        >修改</el-button>-->
      <!--      </el-col>-->
      <!--      <el-col :span="1.5">-->
      <!--        <el-button-->
      <!--          type="danger"-->
      <!--          plain-->
      <!--          icon="el-icon-delete"-->
      <!--          size="mini"-->
      <!--          :disabled="multiple"-->
      <!--          @click="handleDelete"-->
      <!--          v-hasPermi="['system:info:remove']"-->
      <!--        >删除</el-button>-->
      <!--      </el-col>-->
      <!--      <el-col :span="1.5">-->
      <!--        <el-button-->
      <!--          type="warning"-->
      <!--          plain-->
      <!--          icon="el-icon-download"-->
      <!--          size="mini"-->
      <!--          @click="handleExport"-->
      <!--          v-hasPermi="['system:info:export']"-->
      <!--        >导出</el-button>-->
      <!--      </el-col>-->
      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
    </el-row>

    <el-table v-loading="loading" :data="infoList" @selection-change="handleSelectionChange">
      <el-table-column type="selection" width="55" align="center"/>
      <el-table-column label="文件id" align="center" prop="fileId" v-if="columns[0].visible"/>
      <el-table-column label="文件编号" align="center" prop="efilenum" v-if="columns[1].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="listnum" /> -->
      <el-table-column label="列表号" align="center" prop="listId" v-if="columns[2].visible"/>
      <el-table-column label="索引id" align="center" prop="indexId" v-if="columns[3].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="pid" /> -->
      <el-table-column label="ID" align="center" prop="projid" v-if="columns[4].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="dwid" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="fbid" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="fxid" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="jid" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="topnode" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="topnodem" /> -->
      <el-table-column label="案卷ID" align="center" prop="volumeid" v-if="columns[5].visible"/>
      <el-table-column label="旧案卷ID" align="center" prop="oldvolumeid" v-if="columns[6].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="visflag" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="filingflag" /> -->
      <el-table-column label="保存标志" align="center" prop="saveflag" v-if="columns[7].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="openflag" /> -->
      <el-table-column label="检查标志" align="center" prop="checkupflag" v-if="columns[8].visible"/>
      <el-table-column label="完成标志" align="center" prop="finishflag" v-if="columns[9].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="fromid" /> -->
      <el-table-column label="文件题名" align="center" prop="filename" v-if="columns[10].visible" width="380"/>
      <el-table-column label="责任者" align="center" prop="duty" v-if="columns[11].visible"/>
      <el-table-column label="文件编号" align="center" prop="tagnum" v-if="columns[12].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="filenum" /> -->
      <el-table-column label="主题词" align="center" prop="thematic" v-if="columns[13].visible"/>
      <el-table-column label="创建时间" align="center" prop="ctime" width="180" v-if="columns[14].visible">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.ctime, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column>
      <el-table-column label="页数" align="center" prop="pagenumber" v-if="columns[15].visible"/>
      <el-table-column label="密级" align="center" prop="securitylayer" v-if="columns[16].visible"/>
      <el-table-column label="卷内目录中页号" align="center" prop="pageno" v-if="columns[17].visible"/>
      <el-table-column label="文件类型" align="center" prop="filetype" v-if="columns[18].visible"/>
      <el-table-column label="全宗号" align="center" prop="fontsnum" v-if="columns[19].visible"/>
      <el-table-column label="保存期限" align="center" prop="savetime" v-if="columns[20].visible"/>
      <el-table-column label="文件时间" align="center" prop="filetime" width="180" v-if="columns[21].visible">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.filetime, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column>
      <el-table-column label="文件号" align="center" prop="fileno" v-if="columns[22].visible"/>
      <el-table-column label="附件" align="center" prop="fileatt" v-if="columns[23].visible"/>
      <el-table-column label="载体类型" align="center" prop="carriertype" v-if="columns[24].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="ptext" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="carrieru" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="glidenum" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="efile" /> -->
      <el-table-column label="验收日期" align="center" prop="ftime" width="180" v-if="columns[25].visible">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.ftime, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column>
      <el-table-column label="文件总数量" align="center" prop="totalnum" v-if="columns[26].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="inputman" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="etime" width="180">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.etime, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column> -->
      <!-- <el-table-column label="${comment}" align="center" prop="dotnum" /> -->
      <el-table-column label="图片数量" align="center" prop="picnum" v-if="columns[27].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="recnum" /> -->
      <el-table-column label="总数量" align="center" prop="total" v-if="columns[28].visible"/>
      <el-table-column label="纸张类型" align="center" prop="papertype" v-if="columns[29].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="iscom" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="islocate" /> -->
      <el-table-column label="建设单位" align="center" prop="buildorganization" v-if="columns[30].visible"/>
      <el-table-column label="编制单位" align="center" prop="wcompanyId" v-if="columns[31].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="sendflag" /> -->
      <el-table-column label="录制内容" align="center" prop="lcontent" v-if="columns[32].visible"/>
      <el-table-column label="录制公司" align="center" prop="lcompany" v-if="columns[33].visible"/>
      <el-table-column label="录制人" align="center" prop="lman" v-if="columns[34].visible"/>
      <el-table-column label="带长" align="center" prop="llen" v-if="columns[35].visible"/>
      <el-table-column label="录制时间" align="center" prop="ldate" width="180" v-if="columns[36].visible">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.ldate, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column>
      <el-table-column label="事由" align="center" prop="jconten" v-if="columns[37].visible"/>
      <el-table-column label="地点" align="center" prop="jplace" v-if="columns[38].visible"/>
      <el-table-column label="人物" align="center" prop="jman" v-if="columns[39].visible"/>
      <el-table-column label="背景" align="center" prop="jback" v-if="columns[40].visible"/>
      <el-table-column label="摄影者" align="center" prop="jactor" v-if="columns[41].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="jnum" /> -->
      <el-table-column label="底片号" align="center" prop="jbnum" v-if="columns[42].visible"/>
      <el-table-column label="图号" align="center" prop="tnum" v-if="columns[43].visible"/>
      <el-table-column label="图纸比例" align="center" prop="tzoom" v-if="columns[44].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="tflag" /> -->
      <el-table-column label="设计者" align="center" prop="tdesigner" v-if="columns[45].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="tviewer" /> -->
      <el-table-column label="审核" align="center" prop="tassessor" v-if="columns[46].visible"/>
      <el-table-column label="版本" align="center" prop="tvision" v-if="columns[47].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="clistno" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="cpageno" /> -->
      <el-table-column label="档号" align="center" prop="vnum" v-if="columns[48].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="cvnum" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="ctimeEnd" width="180">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.ctimeEnd, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column> -->
      <el-table-column label="项目索引" align="center" prop="projIndex" v-if="columns[49].visible"/>
      <!-- <el-table-column label="${comment}" align="center" prop="treeParent" /> -->
      <!-- <el-table-column label="${comment}" align="center" prop="treeList" /> -->
      <el-table-column label="附注" align="center" prop="comments" v-if="columns[50].visible"/>
      <el-table-column label="摘要" align="center" prop="abstracts" v-if="columns[51].visible"/>
      <el-table-column label="关键字" align="center" prop="keywords" v-if="columns[52].visible"/>
      <el-table-column label="电子文件存放路径" align="center" prop="filepath" v-if="columns[53].visible"/>
      <el-table-column label="id" align="center" prop="id"/>
      <!--      <el-table-column label="文件信息预留1" align="center" prop="fileReserved1" />-->
      <!--      <el-table-column label="文件信息预留2" align="center" prop="fileReserved2" />-->
      <!--      <el-table-column label="文件信息预留3" align="center" prop="fileReserved3" />-->
      <!--      <el-table-column label="文件信息预留4" align="center" prop="fileReserved4" />-->
      <!--      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">-->
      <!--        <template slot-scope="scope">-->
      <!--          <el-button-->
      <!--            size="mini"-->
      <!--            type="text"-->
      <!--            icon="el-icon-edit"-->
      <!--            @click="handleUpdate(scope.row)"-->
      <!--            v-hasPermi="['system:info:edit']"-->
      <!--          >修改</el-button>-->

      <!--          <el-button-->
      <!--            size="mini"-->
      <!--            type="text"-->
      <!--            icon="el-icon-edit"-->
      <!--            @click="Test(scope.row)"-->
      <!--          >test</el-button>-->

      <!--          <el-button-->
      <!--            size="mini"-->
      <!--            type="text"-->
      <!--            icon="el-icon-delete"-->
      <!--            @click="handleDelete(scope.row)"-->
      <!--            v-hasPermi="['system:info:remove']"-->
      <!--          >删除</el-button>-->
      <!--        </template>-->
      <!--      </el-table-column>-->
      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
        <template slot-scope="scope">
          <el-button
              size="mini"
              type="text"
              icon="el-icon-search"
              @click="showDetails(scope.row)"
          >展示
          </el-button>
        </template>
      </el-table-column>
    </el-table>

    <pagination
        v-show="total>0"
        :total="total"
        :page.sync="queryParams.pageNum"
        :limit.sync="queryParams.pageSize"
        @pagination="getList"
    />

    <!-- 文件显示弹窗 -->
    <el-dialog
        :visible.sync="pdfDialogVisible"
        title="文件详情"
        :width="dialogWidth"
        center
    >
      <embed
          :src="pdfUrl"
          type="application/pdf"
          width="100%"
          height="1000px"
      />
    </el-dialog>
    <el-dialog
        :visible.sync="imgDialogVisible"
        title="文件详情"
        :width="dialogWidth"
        center
    >
      <div class="dialog-content">
        <div class="my_button">
          <el-button
              icon="el-icon-download"
              type="success"
              @click="downloadFile"
          >下载</el-button
          >
          <el-button icon="el-icon-printer" type="primary" @click="printFile"
          >打印</el-button
          >
        </div>
      </div>
      <embed :src="blobImage" type="image/jpeg" width="100%" height="1000px" />
    </el-dialog>

    <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
        <el-form-item label="文件id" prop="fileId">
          <el-input v-model="form.fileId" placeholder="请输入文件id"/>
        </el-form-item>
        <el-form-item label="文件编号" prop="efilenum">
          <el-input v-model="form.efilenum" placeholder="请输入文件编号"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="listnum">-->
        <!--            <el-input v-model="form.listnum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="列表号" prop="listId">
          <el-input v-model="form.listId" placeholder="请输入列表号"/>
        </el-form-item>
        <el-form-item label="索引id" prop="indexId">
          <el-input v-model="form.indexId" placeholder="请输入索引id"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="pid">-->
        <!--            <el-input v-model="form.pid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="ID" prop="projid">
          <el-input v-model="form.projid" placeholder="请输入ID"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="dwid">-->
        <!--            <el-input v-model="form.dwid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="fbid">-->
        <!--            <el-input v-model="form.fbid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="fxid">-->
        <!--            <el-input v-model="form.fxid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="jid">-->
        <!--            <el-input v-model="form.jid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="topnode">-->
        <!--            <el-input v-model="form.topnode" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="topnodem">-->
        <!--            <el-input v-model="form.topnodem" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="案卷ID" prop="volumeid">
          <el-input v-model="form.volumeid" placeholder="请输入案卷ID"/>
        </el-form-item>
        <el-form-item label="旧案卷ID" prop="oldvolumeid">
          <el-input v-model="form.oldvolumeid" placeholder="请输入旧案卷ID"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="visflag">-->
        <!--            <el-input v-model="form.visflag" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="filingflag">-->
        <!--            <el-input v-model="form.filingflag" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="保存标志" prop="saveflag">
          <el-input v-model="form.saveflag" placeholder="请输入保存标志"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="openflag">-->
        <!--            <el-input v-model="form.openflag" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="检查标志" prop="checkupflag">
          <el-input v-model="form.checkupflag" placeholder="请输入检查标志"/>
        </el-form-item>
        <el-form-item label="完成标志" prop="finishflag">
          <el-input v-model="form.finishflag" placeholder="请输入完成标志"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="fromid">-->
        <!--            <el-input v-model="form.fromid" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="文件题名" prop="filename">
          <el-input v-model="form.filename" placeholder="请输入文件题名"/>
        </el-form-item>
        <el-form-item label="责任者" prop="duty">
          <el-input v-model="form.duty" placeholder="请输入责任者"/>
        </el-form-item>
        <el-form-item label="文件编号" prop="tagnum">
          <el-input v-model="form.tagnum" placeholder="请输入文件编号"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="filenum">-->
        <!--            <el-input v-model="form.filenum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="主题词" prop="thematic">
          <el-input v-model="form.thematic" placeholder="请输入主题词"/>
        </el-form-item>
        <el-form-item label="创建时间" prop="ctime">
          <el-date-picker clearable
                          v-model="form.ctime"
                          type="date"
                          value-format="yyyy-MM-dd"
                          placeholder="请选择创建时间">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="页数" prop="pagenumber">
          <el-input v-model="form.pagenumber" placeholder="请输入页数"/>
        </el-form-item>
        <el-form-item label="密级" prop="securitylayer">
          <el-input v-model="form.securitylayer" placeholder="请输入密级"/>
        </el-form-item>
        <el-form-item label="卷内目录中页号" prop="pageno">
          <el-input v-model="form.pageno" placeholder="请输入卷内目录中页号"/>
        </el-form-item>
        <el-form-item label="全宗号" prop="fontsnum">
          <el-input v-model="form.fontsnum" placeholder="请输入全宗号"/>
        </el-form-item>
        <el-form-item label="保存期限" prop="savetime">
          <el-input v-model="form.savetime" placeholder="请输入保存期限"/>
        </el-form-item>
        <el-form-item label="文件时间" prop="filetime">
          <el-date-picker clearable
                          v-model="form.filetime"
                          type="date"
                          value-format="yyyy-MM-dd"
                          placeholder="请选择文件时间">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="文件号" prop="fileno">
          <el-input v-model="form.fileno" placeholder="请输入文件号"/>
        </el-form-item>
        <el-form-item label="附件" prop="fileatt">
          <el-input v-model="form.fileatt" placeholder="请输入附件"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="ptext">-->
        <!--            <el-input v-model="form.ptext" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="carrieru">-->
        <!--            <el-input v-model="form.carrieru" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="glidenum">-->
        <!--            <el-input v-model="form.glidenum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="efile">-->
        <!--            <file-upload v-model="form.efile"/>-->
        <!--          </el-form-item>-->
        <el-form-item label="验收日期" prop="ftime">
          <el-date-picker clearable
                          v-model="form.ftime"
                          type="date"
                          value-format="yyyy-MM-dd"
                          placeholder="请选择验收日期">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="文件总数量" prop="totalnum">
          <el-input v-model="form.totalnum" placeholder="请输入文件总数量"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="inputman">-->
        <!--            <el-input v-model="form.inputman" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="etime">-->
        <!--            <el-date-picker clearable-->
        <!--                            v-model="form.etime"-->
        <!--                            type="date"-->
        <!--                            value-format="yyyy-MM-dd"-->
        <!--                            placeholder="请选择${comment}">-->
        <!--            </el-date-picker>-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="dotnum">-->
        <!--            <el-input v-model="form.dotnum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="图片数量" prop="picnum">
          <el-input v-model="form.picnum" placeholder="请输入图片数量"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="recnum">-->
        <!--            <el-input v-model="form.recnum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="总数量" prop="total">
          <el-input v-model="form.total" placeholder="请输入总数量"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="iscom">-->
        <!--            <el-input v-model="form.iscom" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="islocate">-->
        <!--            <el-input v-model="form.islocate" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="建设单位" prop="buildorganization">
          <el-input v-model="form.buildorganization" placeholder="请输入建设单位"/>
        </el-form-item>
        <el-form-item label="编制单位" prop="wcompanyId">
          <el-input v-model="form.wcompanyId" placeholder="请输入编制单位"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="sendflag">-->
        <!--            <el-input v-model="form.sendflag" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="录制内容">
          <editor v-model="form.lcontent" :min-height="192"/>
        </el-form-item>
        <el-form-item label="录制公司" prop="lcompany">
          <el-input v-model="form.lcompany" placeholder="请输入录制公司"/>
        </el-form-item>
        <el-form-item label="录制人" prop="lman">
          <el-input v-model="form.lman" placeholder="请输入录制人"/>
        </el-form-item>
        <el-form-item label="带长" prop="llen">
          <el-input v-model="form.llen" placeholder="请输入带长"/>
        </el-form-item>
        <el-form-item label="录制时间" prop="ldate">
          <el-date-picker clearable
                          v-model="form.ldate"
                          type="date"
                          value-format="yyyy-MM-dd"
                          placeholder="请选择录制时间">
          </el-date-picker>
        </el-form-item>
        <el-form-item label="事由" prop="jconten">
          <el-input v-model="form.jconten" placeholder="请输入事由"/>
        </el-form-item>
        <el-form-item label="地点" prop="jplace">
          <el-input v-model="form.jplace" placeholder="请输入地点"/>
        </el-form-item>
        <el-form-item label="人物" prop="jman">
          <el-input v-model="form.jman" placeholder="请输入人物"/>
        </el-form-item>
        <el-form-item label="背景" prop="jback">
          <el-input v-model="form.jback" placeholder="请输入背景"/>
        </el-form-item>
        <el-form-item label="摄影者" prop="jactor">
          <el-input v-model="form.jactor" placeholder="请输入摄影者"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="jnum">-->
        <!--            <el-input v-model="form.jnum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="底片号" prop="jbnum">
          <el-input v-model="form.jbnum" placeholder="请输入底片号"/>
        </el-form-item>
        <el-form-item label="图号" prop="tnum">
          <el-input v-model="form.tnum" placeholder="请输入图号"/>
        </el-form-item>
        <el-form-item label="图纸比例" prop="tzoom">
          <el-input v-model="form.tzoom" placeholder="请输入图纸比例"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="tflag">-->
        <!--            <el-input v-model="form.tflag" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="设计者" prop="tdesigner">
          <el-input v-model="form.tdesigner" placeholder="请输入设计者"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="tviewer">-->
        <!--            <el-input v-model="form.tviewer" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="审核" prop="tassessor">
          <el-input v-model="form.tassessor" placeholder="请输入审核"/>
        </el-form-item>
        <el-form-item label="版本" prop="tvision">
          <el-input v-model="form.tvision" placeholder="请输入版本"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="clistno">-->
        <!--            <el-input v-model="form.clistno" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="cpageno">-->
        <!--            <el-input v-model="form.cpageno" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="档号" prop="vnum">
          <el-input v-model="form.vnum" placeholder="请输入档号"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="cvnum">-->
        <!--            <el-input v-model="form.cvnum" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="ctimeEnd">-->
        <!--            <el-date-picker clearable-->
        <!--                            v-model="form.ctimeEnd"-->
        <!--                            type="date"-->
        <!--                            value-format="yyyy-MM-dd"-->
        <!--                            placeholder="请选择${comment}">-->
        <!--            </el-date-picker>-->
        <!--          </el-form-item>-->
        <el-form-item label="项目索引" prop="projIndex">
          <el-input v-model="form.projIndex" placeholder="请输入项目索引"/>
        </el-form-item>
        <!--          <el-form-item label="${comment}" prop="treeParent">-->
        <!--            <el-input v-model="form.treeParent" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="${comment}" prop="treeList">-->
        <!--            <el-input v-model="form.treeList" placeholder="请输入${comment}" />-->
        <!--          </el-form-item>-->
        <el-form-item label="附注" prop="comments">
          <el-input v-model="form.comments" placeholder="请输入附注"/>
        </el-form-item>
        <el-form-item label="摘要" prop="abstracts">
          <el-input v-model="form.abstracts" placeholder="请输入摘要"/>
        </el-form-item>
        .

        <el-form-item label="关键字" prop="keywords">
          <el-input v-model="form.keywords" placeholder="请输入关键字"/>
        </el-form-item>
        <el-form-item label="电子文件存放路径" prop="filepath">
          <el-input v-model="form.filepath" placeholder="请输入电子文件存放路径"/>
        </el-form-item>
        <!--          <el-form-item label="文件信息预留1" prop="fileReserved1">-->
        <!--            <el-input v-model="form.fileReserved1" placeholder="请输入文件信息预留1" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="文件信息预留2" prop="fileReserved2">-->
        <!--            <el-input v-model="form.fileReserved2" placeholder="请输入文件信息预留2" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="文件信息预留3" prop="fileReserved3">-->
        <!--            <el-input v-model="form.fileReserved3" placeholder="请输入文件信息预留3" />-->
        <!--          </el-form-item>-->
        <!--          <el-form-item label="文件信息预留4" prop="fileReserved4">-->
        <!--            <el-input v-model="form.fileReserved4" placeholder="请输入文件信息预留4" />-->
        <!--          </el-form-item>-->
      </el-form>

      <div slot="footer" class="dialog-footer">
        <el-button type="primary" @click="submitForm">确 定</el-button>
        <el-button @click="cancel">取 消</el-button>
      </div>
    </el-dialog>


  </div>
</template>

<script>
import {
  getPdf,
  getFileInfoById,
  listFileInfo,
  getFileInfo,
  delFileInfo,
  addFileInfo,
  updateFileInfo,
  removeFileInfoById
} from "@/api/system/fileinfo";
import pdf from 'vue-pdf';
import {getType} from "@/api/system/fileinfo";


export default {
  name: "Info",
  components: {
    pdf
  },
  data() {
    return {
      showAdvancedSearch: false, // 初始时为简单搜索模式
      pdfUrl: '',
      // 遮罩层
      loading: true,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 文件信息表格数据
      infoList: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 10,
        fileId: null,
        efilenum: null,
        listnum: null,
        listId: null,
        indexId: null,
        pid: null,
        projid: null,
        dwid: null,
        fbid: null,
        fxid: null,
        jid: null,
        topnode: null,
        topnodem: null,
        volumeid: null,
        oldvolumeid: null,
        visflag: null,
        filingflag: null,
        saveflag: null,
        openflag: null,
        checkupflag: null,
        finishflag: null,
        fromid: null,
        filename: null,
        duty: null,
        tagnum: null,
        filenum: null,
        thematic: null,
        ctime: null,
        pagenumber: null,
        securitylayer: null,
        pageno: null,
        filetype: null,
        fontsnum: null,
        savetime: null,
        filetime: null,
        fileno: null,
        fileatt: null,
        carriertype: null,
        ptext: null,
        carrieru: null,
        glidenum: null,
        efile: null,
        ftime: null,
        totalnum: null,
        inputman: null,
        etime: null,
        dotnum: null,
        picnum: null,
        recnum: null,
        total: null,
        papertype: null,
        iscom: null,
        islocate: null,
        buildorganization: null,
        wcompanyId: null,
        sendflag: null,
        lcontent: null,
        lcompany: null,
        lman: null,
        llen: null,
        ldate: null,
        jconten: null,
        jplace: null,
        jman: null,
        jback: null,
        jactor: null,
        jnum: null,
        jbnum: null,
        tnum: null,
        tzoom: null,
        tflag: null,
        tdesigner: null,
        tviewer: null,
        tassessor: null,
        tvision: null,
        clistno: null,
        cpageno: null,
        vnum: null,
        cvnum: null,
        ctimeEnd: null,
        projIndex: null,
        treeParent: null,
        treeList: null,
        comments: null,
        abstracts: null,
        keywords: null,
        filepath: null,
        fileReserved1: null,
        fileReserved2: null,
        fileReserved3: null,
        fileReserved4: null
      },
      // 表单参数
      form: {},
      idForm: {},
      // 表单校验
      rules: {},
      columns: [
        {key: 0, label: '文件id', visible: false},
        {key: 1, label: '文件编号', visible: false},
        {key: 2, label: '列表号', visible: false},
        {key: 3, label: '索引id', visible: false},
        {key: 4, label: 'ID', visible: false},
        {key: 5, label: '案卷ID', visible: true},
        {key: 6, label: '旧案卷ID', visible: false},
        {key: 7, label: '保存标志', visible: false},
        {key: 8, label: '检查标志', visible: false},
        {key: 9, label: '完成标志', visible: false},
        {key: 10, label: '文件题名', visible: true},
        {key: 11, label: '责任者', visible: true},
        {key: 12, label: '文件编号', visible: false},
        {key: 13, label: '主题词', visible: false},
        {key: 14, label: '创建时间', visible: true},
        {key: 15, label: '页数', visible: true},
        {key: 16, label: '密级', visible: true},
        {key: 17, label: '卷内目录中页号', visible: true},
        {key: 18, label: '文件类型', visible: false},
        {key: 19, label: '全宗号', visible: false},
        {key: 20, label: '保存期限', visible: true},
        {key: 21, label: '文件时间', visible: false},
        {key: 22, label: '文件号', visible: false},
        {key: 23, label: '附件', visible: false},
        {key: 24, label: '载体类型', visible: true},
        {key: 25, label: '验收日期', visible: false},
        {key: 26, label: '文件总数量', visible: false},
        {key: 27, label: '图片数量', visible: false},
        {key: 28, label: '总数量', visible: false},
        {key: 29, label: '纸张类型', visible: true},
        {key: 30, label: '建设单位', visible: true},
        {key: 31, label: '编制单位', visible: false},
        {key: 32, label: '录制内容', visible: false},
        {key: 33, label: '录制公司', visible: false},
        {key: 34, label: '录制人', visible: false},
        {key: 35, label: '带长', visible: false},
        {key: 36, label: '录制时间', visible: false},
        {key: 37, label: '事由', visible: false},
        {key: 38, label: '地点', visible: false},
        {key: 39, label: '人物', visible: false},
        {key: 40, label: '背景', visible: false},
        {key: 41, label: '摄影者', visible: false},
        {key: 42, label: '底片号', visible: false},
        {key: 43, label: '图号', visible: false},
        {key: 44, label: '图纸比例', visible: false},
        {key: 45, label: '设计者', visible: false},
        {key: 46, label: '审核', visible: false},
        {key: 47, label: '版本', visible: false},
        {key: 48, label: '档号', visible: false},
        {key: 49, label: '项目索引', visible: false},
        {key: 50, label: '附注', visible: false},
        {key: 51, label: '摘要', visible: false},
        {key: 52, label: '关键字', visible: false},
        {key: 53, label: '电子文件存放路径', visible: false}

      ],

      blobImage: "", //图片url
      pdfDialogVisible: false, // 控制弹窗的显示与隐藏
      imgDialogVisible: false, // 控制弹窗的显示与隐藏
      dialogWidth: "70%", // 弹窗的宽度
      dialogHeight: "80vh",
    };
  },
  created() {
    this.getList();
    // this.handleUpdate(row);
  },
  methods: {
    toggleSearchMode() {
      this.showAdvancedSearch = !this.showAdvancedSearch;
    },
    /** 查询文件信息列表 */
    getList() {
      this.loading = true;
      listFileInfo(this.queryParams).then(response => {
        this.infoList = response.rows;
        this.total = response.total;
        this.loading = false;
      });
    },
    // 取消按钮
    cancel() {
      this.open = false;
      this.reset();
    },
    // 表单重置
    reset() {
      this.form = {
        id: null,
        fileId: null,
        efilenum: null,
        listnum: null,
        listId: null,
        indexId: null,
        pid: null,
        projid: null,
        dwid: null,
        fbid: null,
        fxid: null,
        jid: null,
        topnode: null,
        topnodem: null,
        volumeid: null,
        oldvolumeid: null,
        visflag: null,
        filingflag: null,
        saveflag: null,
        openflag: null,
        checkupflag: null,
        finishflag: null,
        fromid: null,
        filename: null,
        duty: null,
        tagnum: null,
        filenum: null,
        thematic: null,
        ctime: null,
        pagenumber: null,
        securitylayer: null,
        pageno: null,
        filetype: null,
        fontsnum: null,
        savetime: null,
        filetime: null,
        fileno: null,
        fileatt: null,
        carriertype: null,
        ptext: null,
        carrieru: null,
        glidenum: null,
        efile: null,
        ftime: null,
        totalnum: null,
        inputman: null,
        etime: null,
        dotnum: null,
        picnum: null,
        recnum: null,
        total: null,
        papertype: null,
        iscom: null,
        islocate: null,
        buildorganization: null,
        wcompanyId: null,
        sendflag: null,
        lcontent: null,
        lcompany: null,
        lman: null,
        llen: null,
        ldate: null,
        jconten: null,
        jplace: null,
        jman: null,
        jback: null,
        jactor: null,
        jnum: null,
        jbnum: null,
        tnum: null,
        tzoom: null,
        tflag: null,
        tdesigner: null,
        tviewer: null,
        tassessor: null,
        tvision: null,
        clistno: null,
        cpageno: null,
        vnum: null,
        cvnum: null,
        ctimeEnd: null,
        projIndex: null,
        treeParent: null,
        treeList: null,
        comments: null,
        abstracts: null,
        keywords: null,
        filepath: null,
        fileReserved1: null,
        fileReserved2: null,
        fileReserved3: null,
        fileReserved4: null
      };
      this.idForm = {
        id: null,
        ids: null
      };
      this.resetForm("form");
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.ids = selection.map(item => item.id)
      this.single = selection.length !== 1
      this.multiple = !selection.length
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "添加文件信息";
    },
    /** 查看pdf按钮操作 */
    handleView(row) {
      this.reset();
      this.form.id = row.id;
      getPdf(this.form).then(response => {

        const encoder = new TextEncoder();
        const uint8Array = encoder.encode(response);

        // 创建ArrayBuffer
        const arrayBuffer = uint8Array.buffer;

        const blob = new Blob([arrayBuffer], {type: 'application/pdf'});
        this.pdfUrl = URL.createObjectURL(blob);
      })
          .catch(error => {
            console.error('Error occurred while fetching the PDF:', error);
          });
    },

    /**  展示细节操作 */
    showDetails(file) {
      getType(file).then((response) => {
        // if (response.toString() === "pdf") {
        //   this.openPDF(file);
        // } else if (response.toString() === "jpg") {
        //   this.openImg(file);
        // }
        if (response.toString() === "jpg" || response.toString() === "jpeg") {
          this.openImg(file);
        } else {
          this.openPDF(file);
        }
      });
    },
    //打开图片
    openImg(file) {
      this.fileForm = file; // 将文件信息保存到fileForm中，以便在getPdf函数中使用
      getPdf(this.fileForm)
          .then((response) => {
            const blob = new Blob([response], {type: "image/jpeg"});
            this.blobImage = URL.createObjectURL(blob);
            this.imgDialogVisible = true; // 显示弹窗
          })
          .catch((error) => {
            console.error("获取图片时出错:", error);
            // 可以添加错误处理逻辑，比如显示一个错误提示框等
          });
    },
    //打开PDF
    openPDF(file) {
      this.fileForm = file; // 将文件信息保存到fileForm中，以便在getPdf函数中使用
      getPdf(this.fileForm)
          .then((response) => {
            const blob = new Blob([response], {type: "application/pdf"});
            this.pdfUrl = URL.createObjectURL(blob);
            this.pdfDialogVisible = true; // 显示弹窗
          })
          .catch((error) => {
            console.error("Error occurred while fetching the PDF:", error);
            // 可以添加错误处理逻辑，比如显示一个错误提示框等
          });
    },
    // 下载文件
    downloadFile() {
      const link = document.createElement("a");
      link.href = this.blobImage;
      link.download = "file.jpg";
      link.click();
    },
    // 打印文件
    printFile() {
      const printWindow = window.open("", "_blank");
      printWindow.document.write(
          `<img src="${this.blobImage}" style="max-width: 100%; height: auto;">`
      );
      printWindow.document.close();
      printWindow.print();
    },

    /** 修改按钮操作 */
    handleUpdate(row) {
      this.reset();
      if (this.ids.length === 0) {
        this.idForm.id = row.id;
      } else {
        this.idForm.ids = this.ids;
      }
      getFileInfoById(this.idForm).then(response => {
        this.form = response.data;
        this.open = true;
        this.title = "修改文件信息";
      })
    },

    /** 修改按钮操作 */
    Test(row) {
      this.reset();
      this.form.id = row.id;
      getType(this.form).then(response => {
        console.log(response)
        console.log(response.data);
      })
    },


    /** 提交按钮 */
    submitForm() {
      this.$refs["form"].validate(valid => {
        if (valid) {
          if (this.form.id != null) {
            updateFileInfo(this.form).then(response => {
              this.$modal.msgSuccess("修改成功");
              this.open = false;
              this.getList();
            });
          } else {
            addFileInfo(this.form).then(response => {
              this.$modal.msgSuccess("新增成功");
              this.open = false;
              this.getList();
            });
          }
        }
      });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      if (this.ids.length === 0) {
        this.idForm.id = row.id;
        removeFileInfoById(this.idForm)
        this.getList();
        this.$modal.msgSuccess("删除成功");
      } else {
        this.idForm.ids = this.ids;
        removeFileInfoById(this.idForm);
        this.getList();
        this.$modal.msgSuccess("删除成功");
      }
    },

    /** 导出按钮操作 */
    handleExport() {
      this.download('system/info/export', {
        ...this.queryParams
      }, `info_${new Date().getTime()}.xlsx`)
    }
  }
};
</script>

<style>
.my_title {
  margin-bottom: 13px;
  font-weight: lighter;
}
</style>
